TARGET = ../../lib/libraft.a
OBJPATH = ./
CFLAGS = -Wall -w  -g -ggdb -O2 -Wno-unused -Wno-sign-compare -Wno-deprecated-declarations -Wno-deprecated -Wl,--no-as-needed -std=c++17\
  -DROCKSDB_PLATFORM_POSIX  -I ../  -I ../../third_party/rocksdb/ -I ../../third_party/rocksdb/include/    -I ../../third_party/ -I ../../third_party/slash/


LFLAGS = -lpthread -lstdc++fs
LLIB = 

OBJS = $(patsubst %.cc,$(OBJPATH)/%.o, $(notdir $(wildcard *.cc)))

$(OBJPATH)/%.o : %.cc
	g++ -c $(CFLAGS) $< -o $@

all : $(TARGET)

$(TARGET) : $(OBJS)
	$(AR) -rcs $(OBJPATH)/$(TARGET) $(OBJS) 

install:
	@mkdir /usr/local/include/raft
	@cp *.h /usr/local/include/raft
	
clean:
	@rm -f $(OBJPATH)/*.o
	@rm -f $(TARGET)
	@rm -rf /usr/local/include/raft
	
	
	

